package cn.gson.crm.model.pojo;

import java.io.Serializable;
import javax.persistence.*;
import java.math.BigDecimal;


/**
 * The persistent class for the FINANCIAL_DATA database table.
 * 
 */
@Entity
@Table(name="FINANCIAL_DATA")
@NamedQuery(name="FinancialData.findAll", query="SELECT f FROM FinancialData f")
public class FinancialData implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@SequenceGenerator(name="FINANCIAL_DATA_FDID_GENERATOR", sequenceName="SEQ_22")
	@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="FINANCIAL_DATA_FDID_GENERATOR")
	@Column(name="FD_ID")
	private long fdId;

	@Column(name="ADVANCE_MONEY")
	private Double advanceMoney;

	
	@Column(name="CONTRACT_SUM")
	private Double contractSum;

	@Column(name="CUST_CNAME")
	private String custCname;

	@Column(name="CUST_ID")
	private Long custId;

	@Column(name="CUST_NAME")
	private String custName;


	@Column(name="GIVE_MONEY")
	private Double giveMoney;

	private Double invoice;

	private Double payment;

	private Double receivable;

	private Double remittance;

	@Column(name="SUM_MONEY")
	private Double sumMoney;

	@Column(name="TOTAL_GOODS")
	private Double totalGoods;

	//bi-directional many-to-one association to Customerinfo
	@ManyToOne
	@JoinColumn(name="CUS_CUST_ID")
	private Customerinfo customerinfo;

	public FinancialData() {
	}

	public long getFdId() {
		return this.fdId;
	}

	public void setFdId(long fdId) {
		this.fdId = fdId;
	}

	public Double getAdvanceMoney() {
		return this.advanceMoney;
	}

	public void setAdvanceMoney(Double advanceMoney) {
		this.advanceMoney = advanceMoney;
	}

	public Double getContractSum() {
		return this.contractSum;
	}

	public void setContractSum(Double contractSum) {
		this.contractSum = contractSum;
	}

	public String getCustCname() {
		return custCname;
	}

	public void setCustCname(String custCname) {
		this.custCname = custCname;
	}

	public String getCustName() {
		return custName;
	}

	public void setCustName(String custName) {
		this.custName = custName;
	}

	public Long getCustId() {
		return this.custId;
	}

	public void setCustId(Long custId) {
		this.custId = custId;
	}

	public Double getGiveMoney() {
		return this.giveMoney;
	}

	public void setGiveMoney(Double giveMoney) {
		this.giveMoney = giveMoney;
	}

	public Double getInvoice() {
		return this.invoice;
	}

	public void setInvoice(Double invoice) {
		this.invoice = invoice;
	}

	public Double getPayment() {
		return this.payment;
	}

	public void setPayment(Double payment) {
		this.payment = payment;
	}

	public Double getReceivable() {
		return this.receivable;
	}

	public void setReceivable(Double receivable) {
		this.receivable = receivable;
	}

	public Double getRemittance() {
		return this.remittance;
	}

	public void setRemittance(Double remittance) {
		this.remittance = remittance;
	}

	public Double getSumMoney() {
		return this.sumMoney;
	}

	public void setSumMoney(Double sumMoney) {
		this.sumMoney = sumMoney;
	}

	public Double getTotalGoods() {
		return this.totalGoods;
	}

	public void setTotalGoods(Double totalGoods) {
		this.totalGoods = totalGoods;
	}

	public Customerinfo getCustomerinfo() {
		return this.customerinfo;
	}

	public void setCustomerinfo(Customerinfo customerinfo) {
		this.customerinfo = customerinfo;
	}

	public FinancialData(long fdId, Double advanceMoney, Double contractSum, String custCname, Long custId,
			String custName, Double giveMoney, Double invoice, Double payment, Double receivable, Double remittance,
			Double sumMoney, Double totalGoods, Customerinfo customerinfo) {
		super();
		this.fdId = fdId;
		this.advanceMoney = advanceMoney;
		this.contractSum = contractSum;
		this.custCname = custCname;
		this.custId = custId;
		this.custName = custName;
		this.giveMoney = giveMoney;
		this.invoice = invoice;
		this.payment = payment;
		this.receivable = receivable;
		this.remittance = remittance;
		this.sumMoney = sumMoney;
		this.totalGoods = totalGoods;
		this.customerinfo = customerinfo;
	}

	public FinancialData(long fdId, Double advanceMoney, Double contractSum, String custCname, Long custId,
			String custName, Double giveMoney, Double invoice, Double payment, Double receivable, Double remittance,
			Double sumMoney, Double totalGoods) {
		super();
		this.fdId = fdId;
		this.advanceMoney = advanceMoney;
		this.contractSum = contractSum;
		this.custCname = custCname;
		this.custId = custId;
		this.custName = custName;
		this.giveMoney = giveMoney;
		this.invoice = invoice;
		this.payment = payment;
		this.receivable = receivable;
		this.remittance = remittance;
		this.sumMoney = sumMoney;
		this.totalGoods = totalGoods;
	}
}